Elasticsearch output Document missing exception 404 您所在的位置:网站首页 document missing elasticsearch Elasticsearch output Document missing exception 404

Elasticsearch output Document missing exception 404

2024-04-25 16:15| 来源: 网络整理| 查看: 265

Thanks for replying. I assume that with default initial installation of all the products involved (couchdb, elasticsearch, logstash), without any modified configuration, it has to work. After creating/updating a couchdb document, the whole reponse of logstash, is:

←[33mFailed action. {:status=>404, :action=>["update", {:_id=>"7772e161f5b0e2b1 abced1679f00045c", :_index=>"kmfile", :_type=>"kmFile", :_routing=>nil}, #"update", "seq"=>106}, @lut={"[action]"=>[{"_id"=>"7772e161f5b0e2b1abced1679f00045c", "action"=>"updat e", "seq"=>106}, "action"], "[_id]"=>[{"_id"=>"7772e161f5b0e2b1abced1679f00045c" , "action"=>"update", "seq"=>106}, "_id"]}>, @cancelled=false, @data={"doc"=>{"$ doctype"=>"kmFile"}, "doc_as_upsert"=>true, "@version"=>"1", "@timestamp"=>"2016 -02-26T15:37:06.311Z", "action"=>"update", "type"=>"kmFile"}, @metadata={"_id"=> "7772e161f5b0e2b1abced1679f00045c", "action"=>"update", "seq"=>106}, @accessors= #{"$doctype"=>"kmFile"}, "doc _as_upsert"=>true, "@version"=>"1", "@timestamp"=>"2016-02-26T15:37:06.311Z", "a ction"=>"update", "type"=>"kmFile"}, @lut={"action"=>[{"doc"=>{"$doctype"=>"kmFi le"}, "doc_as_upsert"=>true, "@version"=>"1", "@timestamp"=>"2016-02-26T15:37:06 .311Z", "action"=>"update", "type"=>"kmFile"}, "action"], "[action]"=>[{"doc"=>{ "$doctype"=>"kmFile"}, "doc_as_upsert"=>true, "@version"=>"1", "@timestamp"=>"20 16-02-26T15:37:06.311Z", "action"=>"update", "type"=>"kmFile"}, "action"], "[doc ][$doctype]"=>[{"$doctype"=>"kmFile"}, "$doctype"], "type"=>[{"doc"=>{"$doctype" =>"kmFile"}, "doc_as_upsert"=>true, "@version"=>"1", "@timestamp"=>"2016-02-26T1 5:37:06.311Z", "action"=>"update", "type"=>"kmFile"}, "type"]}>>], :response=>{" update"=>{"_index"=>"kmfile", "_type"=>"kmFile", "_id"=>"7772e161f5b0e2b1abced16 79f00045c", "status"=>404, "error"=>{"type"=>"document_missing_exception", "reas on"=>"[kmFile][7772e161f5b0e2b1abced1679f00045c]: document missing", "shard"=>"- 1", "index"=>"kmfile"}}}, :level=>:warn}←[0m (kmFile is my document type, stored in $doctype field) Elasticsearch log does not throw any error.

Simple logstash configuration, with elasticsearch output, works ok:

[CODE] input { stdin { } }

filter { grok { match => { "message" => "%{COMBINEDAPACHELOG}" } } date { match => [ "timestamp" , "dd/MMM/yyyy:HH:mm:ss Z" ] } }

output { elasticsearch { hosts => ["localhost:9200"] } stdout { codec => rubydebug } } [/CODE]



【本文地址】

公司简介

联系我们

今日新闻

    推荐新闻

    专题文章
      CopyRight 2018-2019 实验室设备网 版权所有